package cc.ufinity.networkdiagnose.widget;

import android.app.Activity;
import android.view.KeyEvent;
import android.view.MotionEvent;
import android.view.View;
import android.widget.Button;
import android.widget.ListView;
import android.widget.TextView;
import cc.ufinity.networkdiagnose.view.R;

public class Text_Widget extends GeneralTestWidget{

	 private Activity ctx;
	 private TextView textView;
	 private Button reButton;
    private ListView taskDescView;
	public Text_Widget(Activity context) {
		super(context);
		this.ctx=context;
		 inflate(ctx, R.layout.text_widget, this);
//		 textView=(TextView)findViewById(R.id.text_widget);
		 reButton =(Button)findViewById(R.id.task_title);
		 taskDescView = (ListView) this.findViewById(R.id.taskListView);
		 reButton.setOnTouchListener(new OnTouchListener() {
			
			@Override
			public boolean onTouch(View v, MotionEvent event) {
				// TODO Auto-generated method stub
				if(event.getAction()==KeyEvent.ACTION_DOWN){
					reButton.setBackgroundResource(R.drawable.button_right);
				}
				return false;
			}
		});
		 reButton.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				CheckWidget cw = new CheckWidget(ctx);
				cw.start();
				ctx.setContentView(cw);
			}
		});
//		 textView.setText("这个是 验收测试的说明");
	}

}
